// 测试用例

#ifndef COMPILER_ONLINE

#include "header.cpp"

#endif

vector<string>test_1({"flower","flow","flight"});
vector<string>test_2({"dog","racecar","car"});

void Test1()
{
    string ret = Solution().longestCommonPrefix(test_1);
    if(ret=="fl")
    {
        std::cout << "通过测试用例1...OK！" << std::endl;
    }
    else
    {
        std::cout << "没有通过用例1...测试的值是：'flower,flow,flight' " << std::endl;
    }
}

void Test2()
{
    string ret = Solution().longestCommonPrefix(test_2);
    if (ret=="")
    {
        std::cout << "通过测试用例2...OK！" << std::endl;
    }
    else
    {
        std::cout << "没有通过用例2...测试的值是：'dog,racecar,car' " << std::endl;
    }
}

int main()
{
    Test1();
    Test2();
    return 0;
}